package com.tedu.services;

import com.tedu.mapper.SmbmsBillMapper;
import com.tedu.mapper.SmbmsProviderMapper;
import com.tedu.pojo.SmbmsBill;
import com.tedu.pojo.SmbmsBillExample;
import com.tedu.pojo.SmbmsProvider;
import com.tedu.pojo.SmbmsProviderExample;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 用户服务层接口实现类  交给spring管理
 */

@Service  //该组件是服务层的实现类并且交给了spring管理
public class BillServicesImpl implements BillServices {


    @Autowired
    SmbmsBillMapper billMapper;



    @Override
    public List<SmbmsBill> getAllBill() {
        return billMapper.selectByExample(new SmbmsBillExample());
    }

    @Override
    public SmbmsBill getBillById(int bid) {
        return billMapper.selectByPrimaryKey(new Long(bid));
    }
}